-- clear all, to be safe.
clear;

-- open file and give it a table name
open file "OpenSchemaColumns.csv" as table MyTable;

select * from MyTable;

-- apply these update statements against Field1
update MyTable set field1='SqlClient' 		where field1='Microsoft .NET Framework Data Provider for SQL Server';
update MyTable set field1='OracleClient' 	where field1='Microsoft .NET Framework Data Provider for Oracle';
update MyTable set field1='SqlODBC' 		where field1='Microsoft SQL Server ODBC Driver';
update MyTable set field1='OracleODBC' 		where field1='Microsoft Oracle ODBC Driver';
update MyTable set field1='JetODBC' 		where field1='Microsoft Jet ODBC Driver';
update MyTable set field1='SqlOLEDB' 		where field1='Microsoft SQL Server OLEDB Provider';
update MyTable set field1='OracleOLEDB' 	where field1='Microsoft Oracle OLEDB Provider';
update MyTable set field1='JetOLEDB' 		where field1='Microsoft Jet OLEDB Provider';

commit;

-- apply these update statements against Field2
update MyTable set Field2='ProcedureParameters'			where Field2='Procedure Parameters';
update MyTable set Field2='ProcedureParameters'			where Field2='ProcedureColumns';
update MyTable set Field2='ForeignKeys'				where Field2='Foreign Keys';
update MyTable set Field2='ForeignKeys'				where Field2='ForeignKeyColumns';
update MyTable set Field2='ForeignKeys'				where Field2='ForeignKeys';

commit;


select * from MyTable;


-- save table as filename
save table MyTable as file "OpenSchemaColumns_fixed.csv";


--rollback;
